classdef FuzzyRules
    properties
        Name
        Output
        Interval
    end

    methods
        function obj = FuzzyRules(name, membership1, membership2, input1, input2, a, b, c)
            obj.Name = name;
            obj.Interval(1) = min(membership1(1), membership2(1));
            obj.Interval(2) = min(membership1(2), membership2(2));
            obj.Output = a*input1 + b*input2 + c;
        end
        
        function obj = compute(obj, membership1, membership2, input1, input2)
            obj.Interval(1) = min(membership1(1), membership2(1));
            obj.Interval(2) = min(membership1(2), membership2(2));
            obj.Output = a1*input1 + b2*input2 + c3;
        end
            
    end






end
